<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/>
    <title>修改文章</title>
    <hdjs/>
    <bootstrap/>
    <css file="__CONTROL_TPL__/css/css.css"/>
    <style type="text/css">
        .checkbox{
             margin-left:5px;
             width:90px;
             margin-top: 10px;
        }
        textarea{
            width: 300px;
            height: 100px;
        }
    </style>
</head>
<body>
<div class="wrap">
    <div class="title-header">修改文章</div>
    <form action="" method="post" class="form-inline hd-form" enctype="multipart/form-data">
        <table class="table1">
            <tr>
                <th class="w10">文章标题</th>
                <td class="w100">
                    <input type="text" name="title" class="w300" value='{$article.title}'/> 
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">作者</th>
                <td>
                    <input type="text" name="author" class="w200" value="{$article.author}"/>
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">来源</th>
                <td>
                    <input type="text" name="source" class="w200" value="{$article.source}"/>
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">所属分类</th>
                <td>
                    <select name="category_cid" class="w200">
                        <option value="{$article.cid}">{$article.cname}</option>
                        <foreach from="$category" value="$value">
                            <option value="{$value.cid}">{$value._html}{$value.cname}</option>
                        </foreach>
                    </select>
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">缩略图</th>
                <td>
                     <input type="file" name="upload" id="" />
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">文章属性</th>
                <td>
                    <label class="checkbox-inline">
                        热门
                        <input type="checkbox" value="热门" name="attr[]" class="check_input" 
                            <if value="in_array('热门',{$article.attr})">checked="checked"</if>
                        >
                    </label>
                    <label class="checkbox-inline">
                        置顶
                        <input type="checkbox" value="置顶" name="attr[]" class="check_input"
                            <if value="in_array('置顶',{$article.attr})">checked="checked"</if>
                        >
                    </label>
                    <label class="checkbox-inline">
                        推荐
                        <input type="checkbox" value="推荐" name="attr[]" class="check_input"
                            <if value="in_array('推荐',{$article.attr})">checked="checked"</if>
                        >
                    </label>
                    <label class="checkbox-inline">
                        图文
                        <input type="checkbox" value="图文" name="attr[]" class="check_input"
                            <if value="in_array('图文',{$article.attr})">checked="checked"</if>
                        >
                    </label>
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">文章标签</th>
                <td>
                    <foreach from='$tag' value='$value'>
                        <label class="checkbox-inline">
                            {$value.tagname}
                            <input type="checkbox" value="{$value.tid}" name="tag_tid[]" class="check_input"
                            <if value="in_array($value['tid'],$tag_tids)">checked="checked"</if>
                            >
                        </label>
                    </foreach>
                </td>
                <td></td>
            </tr>
             <tr>
                <th class="w100">文章关键字</th>
                <td>
                    <textarea name="keywords" id="" rows="10">{$article.keywords}</textarea>
                </td>
                <td></td>
            </tr>
             <tr>
                <th class="w100">文章描述</th>
                <td>
                    <textarea name="description" id="" cols="30" rows="10">{$article.description}</textarea>
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100">文章摘要</th>
                <td>
                    <keditor  width='300' height='100' name='digest' style="2" content="{$article.digest}"/>
                </td>
                <td></td>
            </tr>
             <tr>
                <th class="w100">文章正文</th>
                <td>
                    <ueditor  width='850' height='300' name='content' style="1" content="{$article.content}"/>
                </td>
                <td></td>
            </tr>
            <tr>
                <th class="w100"></th>
                <td></td>
                <td></td>
            </tr>
            <tr>
                <th class="w100"></th>
                <td></td>
                <td></td>
            </tr>
            <tr>
                <th class="w100"></th>
                <td></td>
                <td></td>
            </tr>
        </table>
        <div class="position-bottom" style='padding-left:125px'>
            <a href="{|U:'index'}"><input type="button" class="hd-success btn-sm" value="取消修改"/></a>
            <input type="hidden" value="{$hd.get.aid}" name="aid"/>
            <input type="submit" class="hd-success btn-sm" value="确认修改"/>
        </div>
    </form>
</div>
</body>
</html>